package net.dodo.pintscreen;

import java.awt.Canvas;
import java.awt.Color;
import java.awt.Graphics;

public class MainCanvas extends Canvas {

	/**
	 * 
	 */
	private static final long serialVersionUID = 3995228156852019427L;

	private static final int COLOR_WHITE = 1;

	private static final int COLOR_BLUE = 2;

	private int color = COLOR_WHITE;

	@Override
	public void paint(Graphics g) {
		switch (color) {
		case COLOR_BLUE:
			g.setColor(new Color(0x0000FF));
			break;
		case COLOR_WHITE:
			g.setColor(new Color(0xFFFFFF));
			break;
		}
		g.fillRect(0, 0, this.getWidth(), this.getHeight());
		super.paint(g);
	}
}
